//
//  ModuleAViewController.m
//  ObjcDemo
//
//  Created by fan on 2021/10/15.
//

#import "ModuleAViewController.h"

@interface ModuleAViewController ()

@end

@implementation ModuleAViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view.
    
    self.view.backgroundColor = [UIColor whiteColor];
    
    UIButton *btn = [UIButton buttonWithType:UIButtonTypeCustom];
    [btn setTitle:@"回调" forState:(UIControlStateNormal)];
    btn.backgroundColor = [UIColor purpleColor];
    btn.frame = CGRectMake(20, 150 ,self.view.frame.size.width - 40 , 40);
    [btn addTarget:self action:@selector(_clickButton:) forControlEvents:(UIControlEventTouchUpInside)];
    [self.view addSubview:btn];
}

-(void)_clickButton:(UIButton *)btn {
    if (self.textCallBack) {
        self.textCallBack(@"_clickButton");
    }
    
}


@end
